class CreateShopAddresses < ActiveRecord::Migration
  def self.up
    create_table :shop_addresses do |t|
      t.references :shop
      t.string :addr, :limit => 140, :null => false
      t.string :addr_description
    end

    add_index :shop_addresses, [:shop_id, :addr], :unique => true
  end

  def self.down
    drop_table :shop_addresses
  end
end
